import uni from '@dcloudio/vite-plugin-uni'
import path from 'path'
import uniReadPagesV3Plugin from './sheep/plugins/uni-read-pages-v3.js'
export default (command, mode) => {
  return {
    // envPrefix: '',
    plugins: [
      uni(),
      uniReadPagesV3Plugin({
        pagesJsonDir: path.resolve(__dirname, './pages.json'),
        includes: ['path', 'aliasPath', 'name', 'meta']
      })
    ],
    server: {
      host: true,
      hmr: {
        overlay: true
      }
    }
  }
}
